/**
 * Element Skipper
 */


const dropElements = (arr, func) => {
  let i;
  for (i = 0; i < arr.length; i++) {
    if (func(arr[i])) break;
  }
  return arr.slice(i);
}

// run the tests
console.log(dropElements([1, 2, 3, 4], function(n) {return n >= 3;}));
// console.log(dropElements([0, 1, 0, 1], function(n) {return n === 1;}));